//
//  PopularityView.swift
//  知乎日报Demo
//
//  Created by Ann on 2017/10/20.
//  Copyright © 2017年 Ann. All rights reserved.
//

import UIKit

class PopularityView: UIView {

    var setCount:Int = 0{
        didSet{
            label.text = String(setCount)
        }
    }
    
    
    fileprivate lazy var label:UILabel = {
        let lab = UILabel()
        lab.textColor = UIColor.white
        lab.font = UIFont.systemFont(ofSize: 16)
        lab.text = ""
 
        return lab
        
    }()
    
    
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        
        self.addSubview(label)
        
        label.backgroundColor = UIColor.white
        
        label.snp.makeConstraints { (make) in
            make.centerX.equalTo(self.snp.centerX)
            make.centerY.equalTo(self.snp.centerY)
        }
        
        label.sizeToFit()
        label.backgroundColor = UIColor.clear
        
    }
    
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    

}
